package com.jackgris.cajeros.rosario;

import com.google.android.maps.MapActivity;
import com.google.android.maps.MapController;
import com.google.android.maps.MapView;
import com.google.android.maps.MyLocationOverlay;
import android.os.Bundle;

public class MapaCajerosDeRosario  extends MapActivity {
	
	private MapView map;
	private MapController controller;
	   
	@Override
	   public void onCreate(Bundle savedInstanceState) {
	      super.onCreate(savedInstanceState);
	      setContentView(R.layout.rosariocajeros);
	      initMapView();
	      initMyLocation();
}

	private void initMapView() {
		map = (MapView)findViewById(R.id.MapaDeRosario);
		controller = map.getController();
		map.setSatellite(true);
		map.setBuiltInZoomControls(true);
	}

	private void initMyLocation() {
		final MyLocationOverlay overlay = new MyLocationOverlay(this, map);
		overlay.enableMyLocation();
		overlay.runOnFirstFix(new Runnable() {
			
			public void run() {
				controller.setZoom(16);
				controller.animateTo(overlay.getMyLocation());
				}
			});
		map.getOverlays().add(overlay);
		}
		protected boolean isRouteDisplayed() {
			return false;
			}
}